﻿using System.Runtime.Serialization;

namespace NGeo.Yahoo.GeoPlanet.Json
{
    [DataContract]
    public class JsonPlace
    {
        [DataMember(Name = "woeid")]
        public int WoeId { get; set; }

        [DataMember(Name = "name")]
        public string Name { get; set; }

        [DataMember(Name = "lang")]
        public string Language { get; set; }

        [DataMember(Name = "uri")]
        public string Uri { get; set; }

        [DataMember(Name = "centroid")]
        public Point Center { get; set; }

        [DataMember(Name = "boundingBox")]
        public BoundingBox BoundingBox { get; set; }

        [DataMember(Name = "areaRank")]
        public int AreaRank { get; set; }

        [DataMember(Name = "popRank")]
        public int PopulationRank { get; set; }

        [DataMember(Name = "postal")]
        public string Postal { get; set; }

        [DataMember(Name = "placeTypeName")]
        public string TypeName { get; set; }

        [DataMember(Name = "placeTypeName attrs")]
        public JsonPlaceTypeAttributes Type { get; set; }

        [DataMember(Name = "country")]
        public string CountryName { get; set; }

        [DataMember(Name = "country attrs")]
        public JsonAdminAttributes Country { get; set; }

        [DataMember(Name = "admin1")]
        public string Admin1Name { get; set; }

        [DataMember(Name = "admin1 attrs")]
        public JsonAdminAttributes Admin1 { get; set; }

        [DataMember(Name = "admin2")]
        public string Admin2Name { get; set; }

        [DataMember(Name = "admin2 attrs")]
        public JsonAdminAttributes Admin2 { get; set; }

        [DataMember(Name = "admin3")]
        public string Admin3Name { get; set; }

        [DataMember(Name = "admin3 attrs")]
        public JsonAdminAttributes Admin3 { get; set; }

        [DataMember(Name = "locality1")]
        public string Locality1Name { get; set; }

        [DataMember(Name = "locality1 attrs")]
        public JsonLocalityAttributes Locality1 { get; set; }

        [DataMember(Name = "locality2")]
        public string Locality2Name { get; set; }

        [DataMember(Name = "locality2 attrs")]
        public JsonLocalityAttributes Locality2 { get; set; }

    }
}
